package work.boom1;

/**
 * @author lijunhao
 * 2023/7/12 作业
 * @description TODO
 */
public class Grade {
    //Java成绩、C#成绩、数据库成绩
    private float javaGrade;
    private float cGrade;
    private float databaseGrade;
    public Grade() {
    }

    public Grade(float javaGrade, float cGrade, float databaseGrade) {
        this.javaGrade = javaGrade;
        this.cGrade = cGrade;
        this.databaseGrade = databaseGrade;

    }
    public float getJavaGrade() {
        return javaGrade;
    }

    public void setJavaGrade(float javaGrade) {
        this.javaGrade = javaGrade;
    }

    public float getcGrade() {
        return cGrade;
    }

    public void setcGrade(float cGrade) {
        this.cGrade = cGrade;
    }

    public float getDatabaseGrade() {
        return databaseGrade;
    }

    public void setDatabaseGrade(float databaseGrade) {
        this.databaseGrade = databaseGrade;
    }
    public float averageGrde(){
        return (javaGrade+cGrade+databaseGrade
                )/3;
    }
    public float totaleGrde (){
         return javaGrade+cGrade+databaseGrade ;
    }
}        



